import java.awt.Point;
import java.awt.geom.Point2D;
import java.util.List;

/**
 * This interface constitutes the required methods for a Chartographer module.
 * The Chartographer module is responsible for maintaining the internal map
 * representation.
 * 
 * @author Emanuel Yifter Lindgren (dv11elr), Anders Lumio (dv11alo)
 *
 */
public interface Chartographer {

    /**
     * Updates the internal map with the data given.
     * 
     * @param update
     *            Sensor data collected by the robot.
     */
    public void updateMap(MapUpdate update);

    /**
     * Gets the internal map representation.
     * 
     * @return the internal map.
     */
    public int[][] getMap();

    /**
     * Gets the position of the robot relative to the internal map.
     * 
     * @return the position
     */
    public int[] getRobotInternalPosition();

    /**
     * Gets the scaling constant of the internal map. That is, if the internal
     * map is made 2 times larger then the real world map. The return value
     * would be 2.
     * 
     * @return the map scale constant.
     */
    public int getInternalMapScale();

    /**
     * Converts a list of points/coordinates relative to the internal map and
     * converts them into a list of real world points/coordinates.
     * 
     * @param internalCoords
     *            list of internal points/coordinates to be converted.
     * @return list of points/coordinates relative to the real world.
     */
    public List<Point2D.Double> convertInternalToRealWorld(
            List<Point> internalCoords);

}
